package com.lipaluma.io;

import java.io.InputStream;
import java.io.OutputStream;
import java.io.Reader;
import java.io.Writer;

/**
 * interface used for creation of {@link SourceReader}.
 * @author Mario
 */
public interface SourceIOFactory {	
	/**
	 * create a fileReader by a {@link Reader}
	 * @param reader entry file
	 * @return the {@link SourceReader}
	 */
	SourceReader createRowReader(Reader reader);

	/**
	 * create a fileReader by a {@link InputStream}
	 * @param InputStream entry file
	 * @return the {@link SourceReader}
	 */
	SourceReader createRowReader(InputStream in);

	/**
	 * create a fileWriter
	 * @param writer final output
	 * @return the {@link SourceWriter}
	 */
	SourceWriter createRowWriter(Writer writer);
	
	/**
	 * create a fileWriter
	 * @param out final output
	 * @return the {@link SourceWriter}
	 */
	SourceWriter createRowWriter(OutputStream out);
}
